package com.cloudkinto.appletservice.order;

import com.baomidou.mybatisplus.extension.service.IService;
import com.cloudkinto.appletservice.order.vo.rakuten.AppletOrderRakutenDetailResponse;
import com.cloudkinto.common.web.PageResult;
import com.cloudkinto.common.web.SingleResult;
import com.cloudkinto.entity.OrderRakutenDo;
import com.cloudkinto.service.order.vo.OrderRakutenSysTipsReq;
import com.cloudkinto.service.orderoutput.vo.OrderOutputAddReq;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * service接口
 * </p>
 *
 * @author 张永远
 * @since 2020-06-03
 */
public interface AppletOrderRakutenService extends IService<OrderRakutenDo> {

    AppletOrderRakutenDetailResponse detail(Long id);

    PageResult getListPage(Map<String, String> map);

    /**
     * 从乐天平台同步订单
     *
     * @param dateStart 订单开始时间
     * @param dateEnd   订单结束时间
     * @param shopId    当前店铺
     * @return
     */
    // int orderSync(String dateStart, String dateEnd, String dateType, long shopId);

    /**
     * @param orderids
     * @param currentUserId
     * @param b
     * @return
     */
    SingleResult queryOrder2SendOut(String[] orderids, Long currentUserId, boolean isAuto, Long companyId);

    SingleResult queryOrder2SendOutNoPackage(String orderid, Long currentUserId, boolean b, Long companyId);

    SingleResult sendOutMatch(List<OrderOutputAddReq> orderOutputAddReqList, Long userId, Long companyId);

    int setOrderSend(Long[] orderids, Long userId);


    List<Map> ordersyncInit(Long currentUserId, Long companyId);

    SingleResult updateSysTips(OrderRakutenSysTipsReq sysTipsReq, Long userId, Long companyId);
    SingleResult updateSysTipsInti(Long orderId);
}
